#include "defer.h"

Defer::Defer(DEFER_FUNC func)
    : m_func(func)
{
    Q_ASSERT(m_func != nullptr);
}

Defer::~Defer()
{
    m_func();
}

